package com.dognessnetwork.operation.dognecklace.service;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.dognessnetwork.operation.baseservice.DeviceTestInfoService;
import com.dognessnetwork.operation.dognecklace.domain.DeviceTestInfo;
import com.dognessnetwork.operation.dognecklace.repository.DeviceTestInfoRepository;

@Service
public class DeviceTestInfoServiceImpl implements DeviceTestInfoService {

	private @Autowired DeviceTestInfoRepository deviceTestInfoRepository;
	
	@Override
	public DeviceTestInfo save(DeviceTestInfo deviceTestInfo) {
		DeviceTestInfo DeviceTestInfo = deviceTestInfoRepository.save(deviceTestInfo);
		return DeviceTestInfo;
	}

	@Override
	public void deleteById(Long id) {
		deviceTestInfoRepository.deleteById(id);
		
	}

	@Override
	public DeviceTestInfo findById(Long id) {
		DeviceTestInfo DeviceTestInfo = deviceTestInfoRepository.findById(id).get();
		return DeviceTestInfo;
	}

}
